package coop.tecso.test.objets.complex;

//src/gen
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.JoinColumns;
import javax.persistence.OneToOne;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Version;

/**
 *
 */
@Entity
@Table(name = "UPLIFT_CAL_COMM")
public class UpliftCalComm implements java.io.Serializable {
	private static final long serialVersionUID = 1L;
	@Id
	@GeneratedValue(strategy = GenerationType.AUTO, generator = "UPLIFT_CAL_COMM_SEQ")
	@SequenceGenerator(name = "UPLIFT_CAL_COMM_SEQ", sequenceName = "UPLIFT_CAL_COMM_SEQ", allocationSize = 1)
	@Column(name = "UPLIFT_CAL_COMM_ID", nullable = false)
	private int id;
	@Version
	@Column(name = "VERSION")
	private int upliftCalCommversion;

	/**
	 * <p>SP para saber que se trata de un incentivo.</p>
	 */
	@Column(name = "COTP_TYPE_FK", length = 6)
	private String cotpTypeFk;

	/**
	 *
	 */
	@Basic(optional = false)
	@Column(name = "CORT_RATE", nullable = false, precision = 3)
	private java.math.BigDecimal cortRate;

	/**
	 *
	 */
	@Basic(optional = false)
	@Column(name = "COAM_AMOUNT", nullable = false, precision = 14, scale = 3)
	private java.math.BigDecimal coamAmount;

	/**
	 *
	 */
	@Basic(optional = false)
	@Column(name = "TCTP_RATE", nullable = false, length = 14, precision = 3)
	private java.math.BigDecimal tctpRate;

	/**
	 *
	 */
	@Basic(optional = false)
	@Column(name = "TCTP_AMOUNT", nullable = false, precision = 11)
	private java.math.BigDecimal tctpAmount;

	/**
	 *
	 */
	@Basic(optional = false)
	@Column(name = "COUPON_USED", nullable = false, length = 10)
	private int couponUsed;

	/**
	 *
	 */
	@Column(name = "COMM_FK", length = 6)
	private String commFk;

	/**
	 *
	 */
	@Column(name = "CURRENCY_FK", length = 6)
	private String currencyFk;

	/**
	 *
	 */
	@Basic(optional = false)
	@Column(name = "TCTP_TYPE_FK", nullable = false, length = 6)
	private java.math.BigDecimal tctpTypeFk;

	/**
	 *
	 */
	@Basic(optional = false)
	@Column(name = "SPTP_TYPE_FK", nullable = false, length = 3)
	private String sptpTypeFk;

	/**
	 *
	 */
	@Column(name = "TEC_CREATION_USER", length = 255)
	private String tecCreationUser;

	/**
	 *
	 */
	@Column(name = "TEC_CREATION_TIMESTAMP")
	private java.sql.Timestamp tecCreationTimestamp;

	/**
	 *
	 */
	@Column(name = "TEC_MODIFICATION_TIMESTAMP")
	private java.sql.Timestamp tecModificationTimestamp;

	/**
	 *
	 */
	@Column(name = "TEC_MODIFICATION_USER", length = 255)
	private String tecModificationUser;

	/**
	 *
	 */
	@Column(name = "TEC_DELETED")
	private Boolean tecDeleted;

	/**
	 *
	 */
	@OneToOne(targetEntity = UpliftCalCommSt.class, mappedBy = "upliftCalComm", optional = false, fetch = FetchType.LAZY)
	@JoinColumns({@JoinColumn(name = "UPLIFT_CAL_COMM_ST_FK",referencedColumnName = "UPLIFT_CAL_COMM_ST_ID",nullable = false)
	})
	private UpliftCalCommSt upliftCalCommSt;

	/**
	 *
	 */
	@OneToOne(targetEntity = UpliftCalCommStHs.class, mappedBy = "upliftCalComm", optional = false, fetch = FetchType.LAZY)
	@JoinColumns({@JoinColumn(name = "UPLIFT_CAL_COMM_ST_HS_FK",referencedColumnName = "UPLIFT_CAL_COMM_ST_HS_ID",nullable = false)
	})
	private UpliftCalCommStHs upliftCalCommStHs;

	public UpliftCalComm() {
	}

	// Constructor for primary key
	public UpliftCalComm(int id) {
		this.id = id;
	}

	/**
	 * Autogenerated key
	 */
	public int getId() {
		return id;
	}

	public int getUpliftCalCommversion() {
		return upliftCalCommversion;
	}

	public void setUpliftCalCommversion(int upliftCalCommversion) {
		this.upliftCalCommversion = upliftCalCommversion;
	}

	public String getCotpTypeFk() {
		return cotpTypeFk;
	}

	public void setCotpTypeFk(String cotpTypeFk) {
		this.cotpTypeFk = cotpTypeFk;
	}

	public java.math.BigDecimal getCortRate() {
		return cortRate;
	}

	public void setCortRate(java.math.BigDecimal cortRate) {
		this.cortRate = cortRate;
	}

	public java.math.BigDecimal getCoamAmount() {
		return coamAmount;
	}

	public void setCoamAmount(java.math.BigDecimal coamAmount) {
		this.coamAmount = coamAmount;
	}

	public java.math.BigDecimal getTctpRate() {
		return tctpRate;
	}

	public void setTctpRate(java.math.BigDecimal tctpRate) {
		this.tctpRate = tctpRate;
	}

	public java.math.BigDecimal getTctpAmount() {
		return tctpAmount;
	}

	public void setTctpAmount(java.math.BigDecimal tctpAmount) {
		this.tctpAmount = tctpAmount;
	}

	public int getCouponUsed() {
		return couponUsed;
	}

	public void setCouponUsed(int couponUsed) {
		this.couponUsed = couponUsed;
	}

	public String getCommFk() {
		return commFk;
	}

	public void setCommFk(String commFk) {
		this.commFk = commFk;
	}

	public String getCurrencyFk() {
		return currencyFk;
	}

	public void setCurrencyFk(String currencyFk) {
		this.currencyFk = currencyFk;
	}

	public java.math.BigDecimal getTctpTypeFk() {
		return tctpTypeFk;
	}

	public void setTctpTypeFk(java.math.BigDecimal tctpTypeFk) {
		this.tctpTypeFk = tctpTypeFk;
	}

	public String getSptpTypeFk() {
		return sptpTypeFk;
	}

	public void setSptpTypeFk(String sptpTypeFk) {
		this.sptpTypeFk = sptpTypeFk;
	}

	public String getTecCreationUser() {
		return tecCreationUser;
	}

	public void setTecCreationUser(String tecCreationUser) {
		this.tecCreationUser = tecCreationUser;
	}

	public java.sql.Timestamp getTecCreationTimestamp() {
		return tecCreationTimestamp;
	}

	public void setTecCreationTimestamp(java.sql.Timestamp tecCreationTimestamp) {
		this.tecCreationTimestamp = tecCreationTimestamp;
	}

	public java.sql.Timestamp getTecModificationTimestamp() {
		return tecModificationTimestamp;
	}

	public void setTecModificationTimestamp(
			java.sql.Timestamp tecModificationTimestamp) {
		this.tecModificationTimestamp = tecModificationTimestamp;
	}

	public String getTecModificationUser() {
		return tecModificationUser;
	}

	public void setTecModificationUser(String tecModificationUser) {
		this.tecModificationUser = tecModificationUser;
	}

	public Boolean getTecDeleted() {
		return tecDeleted;
	}

	public void setTecDeleted(Boolean tecDeleted) {
		this.tecDeleted = tecDeleted;
	}

	public UpliftCalCommSt getUpliftCalCommSt() {
		return upliftCalCommSt;
	}

	public void setUpliftCalCommSt(
UpliftCalCommSt upliftCalCommSt) {
		this.upliftCalCommSt = upliftCalCommSt;
	}

	public UpliftCalCommStHs getUpliftCalCommStHs() {
		return upliftCalCommStHs;
	}

	public void setUpliftCalCommStHs(
UpliftCalCommStHs upliftCalCommStHs) {
		this.upliftCalCommStHs = upliftCalCommStHs;
	}
}
